Skip to content

feat(queue): add event type to log messages in QueueConsumer#707

Open
jekabs-karklins wants to merge 1 commit into
developfrom
fix-add-message-type-to-log
Open

feat(queue): add event type to log messages in QueueConsumer#707
jekabs-karklins wants to merge 1 commit into
developfrom
fix-add-message-type-to-log

Conversation

@jekabs-karklins

Copy link
Copy Markdown
Contributor

Description

Logs should display not only queue name but event type.

Motivation and Context

This would help considerably when debugging

How Has This Been Tested

Updated tests

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR improves QueueConsumer observability by including the consumed event type in the “Received message on queue” log entry, making it easier to debug message flows across queues.

Changes:

  • Extract the first callback argument as eventType in QueueConsumer.start() and include it in the structured log metadata.
  • Update QueueConsumer unit tests to pass (eventType, message, properties) and assert the updated log payload and onMessage invocation.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
src/queue/consumers/QueueConsumer.ts Adds eventType to the “Received message on queue” log metadata.
src/queue/consumers/QueueConsumer.spec.ts Updates tests to reflect the event-type-first callback signature and new log fields.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants